C (177/301)

From:Volker Barthelmann
Date:29 Aug 99 at 01:55:45
Subject:Re: Re: ExecBase & 'RESET:starting PC' exception

From: Volker Barthelmann <volker@vb.franken.de>

On Sat, 28 Aug 1999, Ben Hutchings wrote:

> > > String literals are arrays of const char.
> > >
> > First I've heard of it.
>
> You doubt what I say? Perhaps you should find some decent
> documentation on standard C or C++.
>
> For hysterical raisins, you are allowed to assign string literals to
> objects of type char *. That's just a special case; it doesn't mean
> that they are really arrays of char.

If you're talking about the type of string literals, than (at least in C -
not sure about C++) they definitely are arrays of char, not arrays of
const char.

You're not allowed to modify them, but that's something different. There
is no special case regarding their type or rules for assignment.

Volker